<include file="Public/mobile_head"/>
<link href="{:ADDON_PUBLIC_PATH}/mobile/common.css?v={:SITE_VERSION}" rel="stylesheet" type="text/css">
<body>
<div class="container"> 
  <!-- 订单信息 -->
  <div class="order_info">
    <p class="t">确认信息</p>
    <ul>
      <volist name="lists" id="vo">
        <li class="order_item">
          <div class="info">
            <P class="name">{$vo.title}</P>

            <p class="property"> <span class="colorless">金额</span> <span class="orange">￥{$vo.price|wp_money_format}</span> </p>
            <p class="property"> <span class="colorless">数量</span> <span>{$vo.num|intval}</span> </p>
          </div>
        </li>
      </volist>
    </ul>

    <!--<p class="order_remark">
      <textarea placeholder="给卖家给留言" name="remark" id="remark"></textarea>
    </p>-->
    <p class="total_price"> <span class="orange">共{$total_price|wp_money_format}元</span> </p>
    <a class="btn" href="javascript:void(0)" onClick="doPost()">确认提交</a> </div>
</div>
</body>
</html>
<script type="text/javascript">
function doPost(){
	var remark = $('#remark').val();

	var url = "{:U('add_order')}";
	$.post(url,{'remark':remark},function(res){
		var orderid=parseInt(res);
		if(orderid==0){
			$.Dialog.fail("提交失败");
		}else{
			$url="{:U('choose_pay',array('cid'=>$fenlei[id]))}&order_id="+orderid;
			window.location.href=$url;
		}
	});
}
</script>